{template 'public/header'}

{template 'public/comhead'}

<link rel="stylesheet" type="text/css" href="../addons/yzzc_sun/template/public/ygcss.css">
<style>
    .control_info{margin-top: 7px}
</style>
<ul class="nav nav-tabs">
    <span class="ygxian"></span>
    <div class="ygdangq">当前位置:</div>
    <li class="active"><a href="javascript:void(0);">预订下单</a></li>
    <li><a href="{php echo $this->createWebUrl('order');}"><i class="fa fa-refresh"></i>返回订单列表</a></li>
</ul>
<div class="main ygmain">
    <form  method="post" class="form-horizontal form" enctype="multipart/form-data" >
        <input type="hidden" name="c" value="site" />
        <input type="hidden" name="a" value="entry" />
        <input type="hidden" name="m" value="yzzc_sun" />
        <input type="hidden" name="do" value="order" />
        <input type="hidden" name="op" value="return" />
        <input type="hidden" name="order_id" value="{$order_id}" />
        <input type="hidden" name="type" value="{$type}">
        <div class="row">
            <div class="col-sm-6">
                <div class="panel panel-default">
                    <div class="panel-heading">
                        基础信息
                    </div>
                    <div class="panel-body">
                        <div class="pb15 col-sm-12">
                            <label class="col-xs-12 col-sm-3 col-md-2 control-label">名称:</label>
                            <div class="col-sm-9 control_info">
                                {$order['car_name']}
                            </div>
                        </div>
                        <div class="pb15 col-sm-12">
                            <label class="col-xs-12 col-sm-3 col-md-2 control-label">车牌:</label>
                            <div class="col-sm-9 control_info">
                                {$order['carnum']}
                            </div>
                        </div>
                        <div class="pb15 col-sm-12">
                            <label class="col-xs-12 col-sm-3 col-md-2 control-label">客户:</label>
                            <div class="col-sm-9 control_info">
                                {$order['username']}
                            </div>
                        </div>
                        {if $order['shuttle_name']}
                        <div class="pb15 col-sm-12">
                            <label class="col-xs-12 col-sm-3 col-md-2 control-label">送车人:</label>
                            <div class="col-sm-9 control_info">
                                {$order['shuttle_name']}
                            </div>
                        </div>
                        {/if}
                        {if $order['distribution_name']}
                        <div class="pb15 col-sm-12">
                            <label class="col-xs-12 col-sm-3 col-md-2 control-label">送车人:</label>
                            <div class="col-sm-9 control_info">
                                {$order['distribution_name']}
                            </div>
                        </div>
                        {/if}

                        <div class="pb15 col-sm-12">
                            <label class="col-xs-12 col-sm-3 col-md-2 control-label">租金/天:</label>
                            <div class="col-sm-9 control_info">
                                {$order['money']}
                            </div>
                        </div>
                        <div class="pb15 col-sm-12">
                            <label class="col-xs-12 col-sm-3 col-md-2 control-label">租期:</label>
                            <div class="col-sm-9 control_info">
                                {$order['day']}/天
                            </div>
                        </div>
                        <div class="pb15 col-sm-12">
                            <label class="col-xs-12 col-sm-3 col-md-2 control-label">开始时间:</label>
                            <div class="col-sm-9 control_info">
                                {$order['start_time']}
                            </div>
                        </div>
                        <div class="pb15 col-sm-12">
                            <label class="col-xs-12 col-sm-3 col-md-2 control-label">结束时间:</label>
                            <div class="col-sm-9 control_info">
                                {$order['end_time']}
                            </div>
                        </div>
                </div>
                </div>
            </div>
            {if $type == 1}
            <div class="col-sm-6">
                <div class="panel panel-default ">
                    <div class="panel-heading ">
                        交车信息
                    </div>
                    <div class="panel-body">

                        <div class="form-group" >
                            <label class="col-xs-12 col-sm-3 col-md-2 control-label">交车时间</label>
                            <div class="col-sm-10">
                                {php echo tpl_form_field_date('delivery_start_time','',true)}
                            </div>
                        </div>

                        <div class="form-group" >
                            <label class="col-xs-12 col-sm-3 col-md-2 control-label">车辆仪表</label>
                            <div class="col-sm-10">
                                {php echo tpl_form_field_multi_image('delivery_start_meter');}
                            </div>
                        </div>
                        <div class="form-group" >
                            <label class="col-xs-12 col-sm-3 col-md-2 control-label">车辆图片</label>
                            <div class="col-sm-10">
                                {php echo tpl_form_field_multi_image('delivery_start_pic');}
                            </div>
                        </div>
                    </div>
                </div>
            </div>
            {/if}
            {if $type == 2}
            <div class="col-sm-6">
                <div class="panel panel-default ">
                    <div class="panel-heading ">
                        还车信息
                    </div>
                    <div class="panel-body">
                        <div class="form-group" >
                            <label class="col-xs-12 col-sm-3 col-md-2 control-label">交车时间</label>
                            <div class="col-sm-10">
                                {php echo tpl_form_field_date('delivery_end_time','',true)}
                            </div>
                        </div>

                        <div class="form-group" >
                            <label class="col-xs-12 col-sm-3 col-md-2 control-label">车辆仪表</label>
                            <div class="col-sm-10">
                                {php echo tpl_form_field_multi_image('delivery_end_meter');}
                            </div>
                        </div>
                        <div class="form-group" >
                            <label class="col-xs-12 col-sm-3 col-md-2 control-label">车辆图片</label>
                            <div class="col-sm-10">
                                {php echo tpl_form_field_multi_image('delivery_end_pic');}
                            </div>
                        </div>
                    </div>
                </div>
            </div>
            {/if}
        </div>

        <div class="form-group">
            <input type="submit" name="submit" value="提交资料" class="btn col-lg-3" style="color: white;background-color: #444444;margin-left: 550px;"/>
            <input type="hidden" name="token" value="{$_W['token']}" />
        </div>
    </form>
</div>
<script type="text/javascript">
    $(function(){
        $("#frame-2").show();
        $("#yframe-2").addClass("wyactive");
    })
    layui.use('laydate', function () {
        var laydate = layui.laydate;
        laydate.render({
            elem: '.astime',
            type: 'datetime'
        });

    });
    function check() {
        var a= $('input[name="is_inner"]:checked').val()
        console.log(a)
        if(a==1){
            $('.is_inner1') .show();
            $('.is_inner2') .hide();
        }else{
            $('.is_inner2') .show();
            $('.is_inner1') .hide();
        }
    }
</script>